﻿using FluentValidation;

namespace IdentityService.WebAPI.Controllers.Login.Request;
public record SendCodeByPhoneRequest(string PhoneNumber);
public class SendCodeByPhoneRequestValidator : AbstractValidator<SendCodeByPhoneRequest>
{
    public SendCodeByPhoneRequestValidator()
    {
        RuleFor(e => e.PhoneNumber)
            .NotNull().WithMessage("手机号码不能为空")
            .NotEmpty().WithMessage("手机号码不能为空");
    }
}